From: Melinda Sargeant Sent: Wednesday, December 16, 2015 2:42 PM To: Zedel, Susan FLNR:EX Cc: Helmut Huber Subject: RE: SPAR 95 Hi Susan, Thanks for the error message – that made it easier. I found the following code in the Spr001aParentTreeContribForm.java: private IntegerFieldValidator smpSuccessPctNumeric = new IntegerFieldValidator(this, "smp_success_pct", "SMP Success on parent", false); private IntegerLimitsValidator smpSuccessPctRange = new IntegerLimitsValidator(this, "smp_success_pct", "SMP Success on parent", 0, 25, false); private IntegerLimitsValidator smpSuccessPctRangePW = new IntegerLimitsValidator(this, "smp_success_pct", "SMP Success on parent", 0, 100, false); // For Western White Pine (PW), the smp success pct can go up to 100 private final FieldValidator smpSuccessPctRangeValidator = new FieldValidator() { public ErrorMessage validate() { if(dataBean.getP_vegetation_code().equals("PW")) { return smpSuccessPctRangePW.validate(); } else { return smpSuccessPctRange.validate(); } } }; From the code it looks like it should be working for “PW”, but perhaps the value really is “Pw” at this point? Or something else? If you view the source of the page in your browser, you should be able to find what the vegetation code is at that time. I think we are getting closer! Thanks, Melinda Sargeant Vivid Solutions Inc 250-385-6040 msargeant@vividsolutions.com From: Zedel, Susan FLNR:EX [mailto:Susan.Zedel@gov.bc.ca] Sent: Wednesday, December 16, 2015 11:53 AM To: Melinda Sargeant Cc: Helmut Huber Subject: RE: SPAR 95 Hi Melinda, Yes, it certainly is like a needle in a haystack. The code to check the SMP percent entered on PT Contribution has to be somewhere. I went in to SPAR Test and tried to enter a value higher than 25 for a seedlot and I get the correct error message if I try to save, but I couldn’t find it in the code or package: “SMP Success on parent field must be in the range [0,25]” Susan Zedel P.Ag. Seed Resource Specialist Tree Improvement Branch Ministry of Forests, Lands and Natural Resource Operations Phone: 250-356-1598 Website: www.gov.bc.ca/seedregistry From: Melinda Sargeant [mailto:mSargeant@VividSolutions.com] Sent: Wednesday, December 16, 2015 10:29 AM To: Zedel, Susan FLNR:EX Cc: Helmut Huber Subject: RE: SPAR 95 Hi Susan, I’ve run searches though all the SPAR code looking for ‘PW’ or ‘Pw’, both Java and database, and cannot find any references to a SMP contribution. I have attached the code for the spr_001a_smp_calculation procedure – perhaps what you are looking for is in there? Please let me know if I can search for anything else for you and provide as much detail as possible. There is so much code in these packages it is like searching for a needle in a haystack! Thanks, Melinda Sargeant Vivid Solutions Inc 250-385-6040 msargeant@vividsolutions.com From: Zedel, Susan FLNR:EX [mailto:Susan.Zedel@gov.bc.ca] Sent: Tuesday, December 15, 2015 9:45 AM To: Melinda Sargeant Subject: RE: SPAR 95 Thanks for the packages Melinda. One of the things that the orchard managers want to update is the limitation of what % the SMP contribution is limited to. Initially all seedlots were to be limited to a maximum SMP contribution of 25%. I think in release 3.1 or 3.2 there was a change to allow Species = Pw to have SMP up to 100%. I don’t see that in the packages, but maybe I’m not looking carefully enough. Is there any java or other code for the PR Contribution entry that would set those limits? Susan Zedel P.Ag. Seed Resource Specialist Tree Improvement Branch Ministry of Forests, Lands and Natural Resource Operations Phone: 250-356-1598 Website: www.gov.bc.ca/seedregistry From: Melinda Sargeant [mailto:mSargeant@VividSolutions.com] Sent: Thursday, December 10, 2015 4:35 PM To: Zedel, Susan FLNR:EX; Helmut Huber Cc: Dhillon, Ashley CSNR:EX; Barnes, Matthew J CSNR:EX; Edwards, Cheryl CSNR:EX Subject: RE: SPAR 95 Hi Susan, I have attached three files: 1) An excerpt of the SPR_SEEDLOT package containing the spar_calc_pt_contrib procedure that I think has the calculations you are looking for, 2) An excerpt containing the revision history of the SPR_SEEDLOT package and 3) The entire SPR_SEEDLOT package body itself. Hopefully you can find what you are looking for in there. Thanks, Melinda Sargeant Vivid Solutions Inc 250-385-6040 msargeant@vividsolutions.com From: Zedel, Susan FLNR:EX [mailto:Susan.Zedel@gov.bc.ca] Sent: Thursday, December 10, 2015 4:17 PM To: Helmut Huber; Melinda Sargeant Cc: Dhillon, Ashley CSNR:EX; Barnes, Matthew J CSNR:EX; Edwards, Cheryl CSNR:EX Subject: RE: SPAR 95 Hi Helmut and Melinda, Yes, I have copies of the 2004 Excel spreadsheet that the calculations are based on. I will find some and send them to you. The part of the calculations in SPAR that need to be checked are when SMP (Supplemental Mass Pollination) data is entered on the Seedlot Registration SPR001A Calculation of SMP mix screen, how the GW (Genetic Worth) and Ne (Effective Population Size) is calculated for the SMP mix. Then… when the SMP values are brought into the SPR01A Parent Tree Contribution screen, how the GW and Ne from the SMP is included in the overall calculation for the Seedlot GW and Ne. Orchard managers have said that the values do not look correct. So I’m going to try to get examples of the Excel file for some seedlots that correspond to SPAR seedlots. I don’t know if it’s possible for you to give me the code so that I can get some of our Forest Geneticist brains to have a look at it? Susan Zedel P.Ag. Seed Resource Specialist Tree Improvement Branch Ministry of Forests, Lands and Natural Resource Operations Phone: 250-356-1598 Website: www.gov.bc.ca/seedregistry From: Helmut Huber [mailto:hhuber@VividSolutions.com] Sent: Thursday, December 10, 2015 4:07 PM To: Zedel, Susan FLNR:EX Cc: Dhillon, Ashley CSNR:EX; Barnes, Matthew J CSNR:EX; Edwards, Cheryl CSNR:EX; Sargeant, Melinda CSNR:IN Subject: SPAR 95 Hi Susan, We have started the review of SPAR 95 – there are 10,000 lines of code for this package with several procedures. The first procedure we looked at notes that all calculations are based on a 2004 Excel version of the Seedlot Certification Template. Do you have access to this document and we only need to confirm that all of the calculations in the various procedure refer to this document (or potentially other documents) – or do you want us to reverse engineer this excel sheet? Thanks, helmut